<form class="tableform" method='post' action='index.php?app=b2c&ctl=admin_business_order&act=do_confirm' id="order-confirm-form">
	<div class="division">
        <input type="hidden" name="order_id" value="<{$order_id}>">
		<input type="hidden" name="b_order_id" value="<{$b_order_id}>">
		<table cellpadding="0" cellspacing="0"  class="gridlist">
		    <thead>
			<tr>
				<th><{t}>货号<{/t}></th>
				<th><{t}>商品名称<{/t}></th>
				<th><{t}>结算价<{/t}></th>
				<th><{t}>计划数量<{/t}></th>
				<th><{t}>确认数量<{/t}></th>
				<th><{t}>确认状态<{/t}></th>
				<!--th><{t}>推荐商品<{/t}></th-->
			</tr>
			</thead>
			<tbody>
			<{if count($item.goods) > 0}>
				<{foreach from=$item.goods item=aProduct}>
				<tr>
					<td><{$aProduct.bn}></td>
					<td><{$aProduct.name}></td>
					<td><{$aProduct.price}></td>
					<td><{$aProduct.quantity}></td>
					<td>
						<{if $aProduct.state != '1'}>
						<{input type="text" vtype="required&&number" name="confirm_num[{$aProduct.obj_id}]" value=$aProduct.has_confirm_num  width="50"}>
						<{else}>
						<{$aProduct.has_confirm_num}>
						<{/if}>
					</td>
					<td><{if $aProduct.state == '1'}><{t}>已确认<{/t}><{else}><{t}>未确认<{/t}><{/if}></td>
					<!--td><{input type="object" object="goods@b2c" return_url=""  filter=$aProduct.glink_filter textcol="name" name="r_goods_id[{$aProduct.goods_id}]" value=$aProduct.glink.r_goods_id}></td-->
				</tr>
				<{/foreach}>
			<{else}>
			    <tr><td colspan=6><{t}>暂无数据<{/t}></td></tr>
			<{/if}>
			</tbody>
		</table>
	</div>
</form>
<{if $status == 0 && $order_status != 'dead'}>
<div class="table-action">
	<{button label=$___b2c="确认"|t:'b2c' id="order-confirm-form-submit" class="order-action" type="button"}>
</div>
<{/if}>

<script type="text/javascript">
(function(){
    var _form = $('order-confirm-form');
    var btn =$('order-confirm-form-submit');
    _form.store('target',{
    	onRequest:function() {
    	},
        onComplete:function(){
        },
        onSuccess:function(response){
            var hash_res_obj = JSON.decode(response);
            if (hash_res_obj.success != undefined && hash_res_obj.success != ""){
                window.close();
				window.opener.location.reload();
            }else{}
        }
    });
	btn.addEvent('click',function(){
		_form.fireEvent('submit',{stop:$empty});
	});
})();

</script>